<template>
  <div id="index">
    <div class="typeArea">
      <div class="logo">
        <img src="../../assets/image/detailPage_logo.png" alt="">
      </div>
      <div class="btn">大屏</div>
      <div class="banner">
        <img src="../../assets/image/detailPage_benner.png" alt="">
      </div>
      <div class="tit">
        {{ res.name }}
      </div>
      <div v-infinite-scroll="load" class="txt">
        {{ res.description }}
      </div>
      <div class="image">
        <img :src="`data:image/jpeg;base64,${res.p1[0]}`" alt="">
        <video controls="controls">
          <source src="" type="video/mp4">
        </video>
      </div>
    </div>

  </div>
</template>

<script>
import { getDetailByid } from '../../api/detailPage'
import drawMixin from '../../utils/drawMixin' // 自适应缩放
export default {
  name: 'QsgSystemIndex',
  mixins: [drawMixin],
  data() {
    return {
      res: {}
    }
  },

  mounted() {
    const userId = this.$route.params.id
    console.log(userId)
    // 使用 userId 进行相应的逻辑处理

    this.getDetail()
  },
  methods: {
    async getDetail() {
      const res = await getDetailByid(this.$route.params.id)
      console.log(res.p1[0])
      this.res = res
    }
  }
}
</script>

<style lang="scss" scoped>
//全局样式部分！！！！
* {
  margin: 0;
  padding: 0;
  list-style-type: none;
  outline: none;
  box-sizing: border-box;
}
html {
  margin: 0;
  padding: 0;
}
body {
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.2em;
  background-color: #f1f1f1;
  margin: 0;
  padding: 0;
}
// a {
//   color: #343440;
//   text-decoration: none;
// }
  #index {
  // color: #d3d6dd;
  // width: 1920px;
  // height: 1080px;
    width: 100%;
    height: 130%;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  transform-origin: left top;
  // overflow: hidden;
  margin-bottom: 100px;
  .typeArea {
    margin: 0 auto;
    width: 1600px;
    padding-top: 50px;
 .logo {
    margin: 157px 0 91px 0;
    width: 328px;
   height: 81px;
        img {
      width: 100%;
      height: 100%;
    }
  }
  .banner {
    width: 98.99vw;
    height: 360px;
    position: relative;
  margin-left: -13.45%; /* 用于实现左侧超出版心的效果 */
  // margin-right: -50%; /* 用于实现右侧超出版心的效果 */
  overflow: hidden;
    img {
      width: 100%;
      height: 100%;
    }
  }
  .btn {
    width: 100px;
    height: 80px;
    background-color: rgb(70, 230, 171);
    text-align: center;
    color: white;
    line-height: 80px;
    font-weight: 800;
  }
  .tit {
  margin-top: 121px;
	// width: 421px;
	height: 33px;
	font-family: AdobeHeitiStd-Regular;
	font-size: 35px;
	font-weight: normal;
	font-stretch: normal;
	line-height: 23px;
	letter-spacing: 0px;
	color: #484759;
  }
  .txt{
    font-family: AdobeHeitiStd-Regular;
	font-size: 19px;
	font-weight: normal;
	font-stretch: normal;
	line-height: 23px;
	letter-spacing: 0px;
	color: #484759;
  margin-top: 30px;
  }
  .image {
    margin-top: 20px;
  }
  }

  }
</style>
